Terminal Interaction with Different User Plane Function Entities

ABSTRACT

A data transmission method, a device, and a data transmission system are provided to implement local interaction between two terminals when the two terminals are served by different UPF entities. The method performed by a first user plane function entity includes receiving a data packet from a first terminal through an uplink path corresponding to the first terminal, where the data packet carries addressing information of a second terminal; determining path information of a second user plane function entity based on information about the uplink path corresponding to the first terminal and the addressing information of the second terminal; sending the data packet to the second user plane function entity based on the path information of the second user plane function entity; and sending the data packet to the second terminal through a downlink path corresponding to the second terminal.

CROSS-REFERENCE TO RELATED APPLICATIONS

This application is a continuation of International Patent ApplicationNo. PCT/CN2018/101432, filed on Aug. 21, 2018, which claims priority toChinese Patent Application No. 201710758898.2, filed on Aug. 29, 2017.The disclosures of the aforementioned applications are herebyincorporated by reference in their entireties.

TECHNICAL FIELD

This application relates to the field of communications technologies,and in particular, to a data transmission method, a device, and a datatransmission system.

BACKGROUND

A local area network (LAN) is a computer communications network in whichall computers, external devices, databases, and the like in a localgeographical area such as a school, a factory, or a department areconnected to each other. The LAN can be connected to a remote local areanetwork, a remote database, or a remote data center by using a datacommunications network or a dedicated data circuit, to form aninformation processing system that covers a wide area. As a newenterprise office mode and a smart home mode emerge, disadvantages of awired LAN and a wireless LAN (WLAN) with respect to complex deployment,flexibility, mobility, and coverage are exposed. This promotes furtherdevelopment of a LAN technology, to meet a requirement of a futureapplication for the LAN.

A network that directly provides a LAN service based on a wide coveragefeature of a mobile network is referred to as a mobile local areanetwork (MLAN). The MLAN may be applied in a wider mobile networkcoverage range. To be specific, whether users are in a same region,LAN-based data exchange or communication can be implemented, providedthat the users join a same MLAN. Based on the mobile network that haswide coverage, creation, scaling, migration, and adjustment of the MLANmay be automatically completed by the mobile network, without manualintervention. In addition, the MLAN may be customized as required, anddifferent MLANs are securely isolated from each other.

However, in the MLAN, when two terminals are served by different userplane function (UPF) entities, there is no related solution forimplementing local interaction between the two terminals.

SUMMARY

Embodiments of this application provide a data transmission method, adevice, and a data transmission system, to implement local interactionbetween two terminals when the two terminals are served by different UPFentities.

To achieve the foregoing objective, the embodiments of this applicationprovide the following technical solutions.

According to a first aspect, a data transmission method is provided, andthe method includes receiving, by a first user plane function entity, adata packet from a first terminal through an uplink path correspondingto the first terminal, where the data packet carries addressinginformation of a second terminal, and the first user plane functionentity is a user plane function entity currently accessed by the firstterminal; determining, by the first user plane function entity, pathinformation of the second user plane function entity based oninformation about the uplink path corresponding to the first terminaland the addressing information of the second terminal, where the seconduser plane function entity is a user plane function entity currentlyaccessed by the second terminal; sending, by the first user planefunction entity, the data packet to the second user plane functionentity based on the path information of the second user plane functionentity; and sending, by the second user plane function entity, the datapacket to the second terminal through a downlink path corresponding tothe second terminal. Based on the data transmission method provided inthis embodiment of this application, after receiving the data packetfrom the first terminal through the uplink path corresponding to thefirst terminal, the first user plane function entity may determine thepath information of the second user plane function entity based on theinformation about the uplink path corresponding to the first terminaland the addressing information of the second terminal, and may furthersend the data packet to the second user plane function entity based onthe path information of the second user plane function entity; and thesecond user plane function entity sends the data packet to the secondterminal through the downlink path corresponding to the second terminal.This can implement local interaction between the two terminals when thetwo terminals are served by different user plane function entities.

In a possible design, the determining, by the first user plane functionentity, path information of a second user plane function entity based oninformation about the uplink path corresponding to the first terminaland the addressing information of the second terminal includesdetermining, by the first user plane function entity based on theinformation about the uplink path corresponding to the first terminal,an identity of a mobile local area network MLAN to which the firstterminal subscribes; and determining, by the first user plane functionentity, the path information of the second user plane function entitybased on the identity of the MLAN and the addressing information of thesecond terminal. Based on this solution, the first user plane functionentity may determine the path information of the second user planefunction entity.

In a possible design, after the determining, by the first user planefunction entity based on the information about the uplink pathcorresponding to the first terminal, an identity of an MLAN to which thefirst terminal subscribes, the method further includes determining, bythe first user plane function entity based on the identity of the MLANand the addressing information of the second terminal, that informationabout the downlink path corresponding to the second terminal is notstored. In this way, the first user plane function entity may determinethat the first terminal and the second terminal are served by differentuser plane function entities.

In a possible design, the determining, by the first user plane functionentity based on the information about the uplink path corresponding tothe first terminal, an identity of an MLAN to which the first terminalsubscribes includes determining, by the first user plane function entitybased on the information about the uplink path corresponding to thefirst terminal and a first correspondence, the identity of the MLAN towhich the first terminal subscribes, where the first correspondenceincludes a correspondence between the information about the uplink pathcorresponding to the first terminal and the identity of the MLAN. Basedon this solution, the first user plane function entity may determine theidentity of the MLAN to which the first terminal subscribes.

In a possible design, the method further includes obtaining, by thefirst user plane function entity, the identity of the MLAN to which thefirst terminal subscribes and the information about the uplink pathcorresponding to the first terminal; and establishing, by the first userplane function entity, the first correspondence based on the identity ofthe MLAN and the information about the uplink path corresponding to thefirst terminal. Based on this solution, the first user plane functionentity may establish the first correspondence.

In a possible design, the determining, by the first user plane functionentity, the path information of the second user plane function entitybased on the identity of the MLAN and the addressing information of thesecond terminal includes determining, by the first user plane functionentity, the path information of the second user plane function entitybased on the identity of the MLAN, the addressing information of thesecond terminal, and a second correspondence, where the secondcorrespondence includes a correspondence between the addressinginformation of the second terminal, the path information of the seconduser plane function entity, and the identity of the MLAN. Based on thissolution, the first user plane function entity may determine the pathinformation of the second user plane function entity.

In a possible design, the method further includes obtaining, by thefirst user plane function entity, the addressing information of thesecond terminal, the path information of the second user plane functionentity, and the identity of the MLAN; and establishing, by the firstuser plane function entity, the second correspondence based on theaddressing information of the second terminal, the path information ofthe second user plane function entity, and the identity of the MLAN.Based on this solution, the first user plane function entity mayestablish the second correspondence.

In a possible design, the obtaining, by the first user plane functionentity, the addressing information of the second terminal, the pathinformation of the second user plane function entity, and the identityof the MLAN includes receiving, by the first user plane function entityfrom a session management function entity, the addressing information ofthe second terminal, the path information of the second user planefunction entity, and the identity of the MLAN. Based on this solution,the first user plane function entity may obtain the addressinginformation of the second terminal, the path information of the seconduser plane function entity, and the identity of the MLAN.

In a possible design, the determining, by the first user plane functionentity, the path information of the second user plane function entitybased on the identity of the MLAN and the addressing information of thesecond terminal includes sending, by the first user plane functionentity, the identity of the MLAN and the addressing information of thesecond terminal to the session management function entity, where theidentity of the MLAN and the addressing information of the secondterminal are used to determine the path information of the second userplane function entity; and receiving, by the first user plane functionentity, the path information of the second user plane function entityfrom the session management function entity. Based on this solution, thefirst user plane function entity may determine the path information ofthe second user plane function entity.

In a possible design, the information about the uplink pathcorresponding to the first terminal includes a tunnel identifier of thefirst user plane function entity allocated for the first terminal, theinformation about the downlink path corresponding to the second terminalincludes a tunnel identifier of an access device allocated for thesecond terminal, and the path information of the second user planefunction entity includes a tunnel identifier of the second user planefunction entity.

According to a second aspect, a data transmission method is provided,and the method includes receiving, by a first user plane functionentity, a data packet from a first terminal through an uplink pathcorresponding to the first terminal, where the data packet carriesaddressing information of a second terminal, and the first user planefunction entity is a user plane function entity currently accessed bythe first terminal; determining, by the first user plane functionentity, path information of a second user plane function entity based oninformation about the uplink path corresponding to the first terminaland the addressing information of the second terminal, where the seconduser plane function entity is a user plane function entity currentlyaccessed by the second terminal; sending, by the first user planefunction entity, the data packet to the second user plane functionentity based on the path information of the second user plane functionentity; and receiving, by the second user plane function entity, thedata packet from the first user plane function entity, and sending thedata packet to the second terminal through a downlink path correspondingto the second terminal. Based on the data transmission method providedin this embodiment of this application, after receiving the data packetfrom the first terminal through the uplink path corresponding to thefirst terminal, the first user plane function entity may determine thepath information of the second user plane function entity based on theinformation about the uplink path corresponding to the first terminaland the addressing information of the second terminal, and may furthersend the data packet to the second user plane function entity based onthe path information of the second user plane function entity; and thesecond user plane function entity sends the data packet to the secondterminal through the downlink path corresponding to the second terminal.This can implement local interaction between the two terminals when thetwo terminals are served by different user plane function entities.

In a possible design, the method further includes determining, by thesecond user plane function entity based on the path information of thesecond user plane function entity and the addressing information of thesecond terminal, the downlink path corresponding to the second terminal.Based on the solution, the second user plane function entity maydetermine the downlink path corresponding to the second terminal.

In a possible design, the determining, by the second user plane functionentity based on the path information of the second user plane functionentity and the addressing information of the second terminal, thedownlink path corresponding to the second terminal includes determining,by the second user plane function entity based on the path informationof the second user plane function entity, an identity of a mobile localarea network MLAN to which the second terminal subscribes; anddetermining, by the second user plane function entity based on theidentity of the MLAN and the addressing information of the secondterminal, the downlink path corresponding to the second terminal. Basedon the solution, the second user plane function entity may determine thedownlink path corresponding to the second terminal.

In a possible design, the determining, by the second user plane functionentity based on the path information of the second user plane functionentity, an identity of an MLAN to which the second terminal subscribesincludes determining, by the second user plane function entity based onthe path information of the second user plane function entity and athird correspondence, the identity of the MLAN to which the secondterminal subscribes, where the third correspondence includes acorrespondence between the path information of the second user planefunction entity and the identity of the MLAN. Based on this solution,the second user plane function entity may determine the identity of theMLAN to which the second terminal subscribes.

In a possible design, the determining, by the second user plane functionentity based on the identity of the MLAN and the addressing informationof the second terminal, the downlink path corresponding to the secondterminal includes determining, by the second user plane function entitybased on the identity of the MLAN, the addressing information of thesecond terminal, and a fourth correspondence, the downlink pathcorresponding to the second terminal, where the fourth correspondenceincludes a correspondence between information about the downlink pathcorresponding to the second terminal, the addressing information of thesecond terminal, and the identity of the MLAN. Based on the solution,the second user plane function entity may determine the downlink pathcorresponding to the second terminal.

In a possible design, the method further includes obtaining, by thesecond user plane function entity, the path information of the seconduser plane function entity and the identity of the MLAN; andestablishing, by the second user plane function entity, the thirdcorrespondence based on the path information of the second user planefunction entity and the identity of the MLAN. Based on this solution,the second user plane function entity may establish the thirdcorrespondence.

In a possible design, the method further includes obtaining, by thesecond user plane function entity, the addressing information of thesecond terminal, where the addressing information of the second terminalincludes an internet protocol IP address of the second terminal or amedia access control MAC address of the second terminal. Based on thissolution, the second user plane function entity may obtain theaddressing information of the second terminal.

In a possible design, the addressing information of the second terminalincludes the IP address of the second terminal and the obtaining, by thesecond user plane function entity, the addressing information of thesecond terminal includes receiving, by the second user plane functionentity, the IP address of the second terminal from a session managementfunction entity, where the IP address of the second terminal isdetermined based on the identity of the MLAN. Based on this solution,the second user plane function entity may obtain the IP address of thesecond terminal.

In a possible design, the addressing information of the second terminalincludes the MAC address of the second terminal and the obtaining, bythe second user plane function entity, the addressing information of thesecond terminal includes in a process of establishing an MLAN session,receiving, by the second user plane function entity, the MAC address ofthe second terminal from the second terminal. Based on this solution,the second user plane function entity may obtain the MAC address of thesecond terminal.

In a possible design, the addressing information of the second terminalincludes the MAC address of the second terminal and the obtaining, bythe second user plane function entity, the addressing information of thesecond terminal includes receiving, by the second user plane functionentity, a dynamic host configuration protocol DHCP request from thesecond terminal through the uplink path of the second terminal, wherethe DHCP request carries the MAC address of the second terminal;sending, by the second user plane function entity, the DHCP request tothe session management function entity; and receiving, by the seconduser plane function entity, the MAC address of the second terminal fromthe session management function entity. Based on this solution, thesecond user plane function entity may obtain the MAC address of thesecond terminal.

In a possible design, the addressing information of the second terminalincludes the MAC address of the second terminal and the obtaining, bythe second user plane function entity, the addressing information of thesecond terminal includes receiving, by the second user plane functionentity, the DHCP request from the second terminal through the uplinkpath of the second terminal, where the DHCP request carries the MACaddress of the second terminal; and parsing, by the first user planefunction entity, the DHCP request to obtain the MAC address of thesecond terminal. Based on this solution, the second user plane functionentity may obtain the MAC address of the second terminal.

In a possible design, the method further includes obtaining, by thesecond user plane function entity, the identity of the MLAN to which thesecond terminal subscribes and the information about the downlink pathcorresponding to the second terminal; and establishing, by the seconduser plane function entity, the fourth correspondence based on theidentity of the MLAN, the addressing information of the second terminal,and the information about the downlink path corresponding to the secondterminal. Based on this solution, the second user plane function entitymay establish the fourth correspondence.

In a possible design, before the receiving, by the second user planefunction entity, the DHCP request from the second terminal through theuplink path of the second terminal, the method further includesobtaining, by the second user plane function entity, the informationabout the uplink path corresponding to the second terminal, the identityof the MLAN to which the second terminal subscribes, and the informationabout the downlink path corresponding to the second terminal;establishing, by the second user plane function entity, a fifthcorrespondence based on the information about the uplink pathcorresponding to the second terminal, the information about the downlinkpath corresponding to the second terminal, and the identity of the MLAN;where the fifth correspondence includes a correspondence between theinformation about the uplink path corresponding to the second terminal,the information about the downlink path corresponding to the secondterminal, and the identity of the MLAN; and after the receiving, by thesecond user plane function entity, the DHCP request from the secondterminal through the uplink path of the second terminal, the methodfurther includes establishing, by the second user plane function entity,the fourth correspondence based on the fifth correspondence and the MACaddress of the second terminal. Based on this solution, the second userplane function entity may establish the fourth correspondence.

In a possible design, the information about the uplink pathcorresponding to the first terminal includes a tunnel identifier of thefirst user plane function entity allocated for the first terminal, theinformation about the downlink path corresponding to the second terminalincludes a tunnel identifier of an access device allocated for thesecond terminal, and the path information of the second user planefunction entity includes a tunnel identifier of the second user planefunction entity.

According to a third aspect, a first user plane function entity isprovided. The first user plane function entity has a function ofimplementing the method in the first aspect. The function may beimplemented by hardware, or may be implemented by the hardware byexecuting corresponding software. The hardware or the software includesone or more modules corresponding to the function.

According to a fourth aspect, a first user plane function entityincluding a processor and a memory is provided. The memory is configuredto store a computer executable instruction; and when the first userplane function entity runs, the processor executes the computerexecutable instruction stored in the memory, and the first user planefunction entity is enabled to perform the data transmission method inany possible implementation of the first aspect.

According to a fifth aspect, a computer-readable storage medium isprovided, where the computer-readable storage medium stores aninstruction, and when the instruction is run on a computer, the computeris enabled to perform the data transmission method in any possibleimplementation of the first aspect.

According to a sixth aspect, a computer program product including aninstruction is provided. When the instruction is run on a computer, thecomputer is enabled to perform the data transmission method in anypossible implementation of the first aspect.

According to a seventh aspect, a chip system is provided. The chipsystem includes a processor configured to support a first user planefunction entity in implementing functions in the foregoing aspects, forexample, determining the path information of the second user planefunction entity based on the information about the uplink pathcorresponding to the first terminal and the addressing information ofthe second terminal. In a possible design, the chip system furtherincludes a memory. The memory is configured to store a programinstruction and data that are required by the first user plane functionentity. The chip system may include a chip, or may include a chip andanother discrete component.

For technical effects brought by any design manner of the third aspectto the seventh aspect, refer to technical effects brought by differentdesign manners of the first aspect. Details are not described hereinagain.

According to an eighth aspect, a data transmission system is provided,and the data transmission system includes a first user plane functionentity and a second user plane function entity. The first user planefunction entity is configured to receive a data packet from a firstterminal through an uplink path corresponding to the first terminal,where the data packet carries addressing information of a secondterminal, and the first user plane function entity is a user planefunction entity currently accessed by the first terminal. The first userplane function entity is further configured to determine pathinformation of a second user plane function entity based on informationabout the uplink path corresponding to the first terminal and theaddressing information of the second terminal, where the second userplane function entity is a user plane function entity currently accessedby the second terminal. The first user plane function entity is furtherconfigured to send the data packet to the second user plane functionentity based on the path information of the second user plane functionentity. The second user plane function entity is configured to receivethe data packet from the first user plane function entity, and send thedata packet to the second terminal through a downlink path correspondingto the second terminal. Based on the data transmission system providedin this embodiment of this application, after receiving the data packetfrom the first terminal through the uplink path corresponding to thefirst terminal, the first user plane function entity may determine thepath information of the second user plane function entity based on theinformation about the uplink path corresponding to the first terminaland the addressing information of the second terminal, and may furthersend the data packet to the second user plane function entity based onthe path information of the second user plane function entity; and thesecond user plane function entity sends the data packet to the secondterminal through the downlink path corresponding to the second terminal.This can implement local interaction between the two terminals when thetwo terminals are served by different user plane function entities.

The aspects or other aspects in this application may be clearer andeasier to understand in descriptions in the following embodiments.

BRIEF DESCRIPTION OF DRAWINGS

FIG. 1 is a schematic structural diagram of a data transmission systemaccording to an embodiment of this application;

FIG. 2 is a schematic diagram of a data transmission system applied in5G according to an embodiment of this application;

FIG. 3 is a schematic diagram of a hardware apparatus of acommunications device according to an embodiment of this application;

FIG. 4A, FIG. 4B, and FIG. 4C are a schematic flowchart 1 of a datatransmission method according to an embodiment of this application;

FIG. 5A, FIG. 5B, and FIG. 5C are a schematic flowchart 2 of a datatransmission method according to an embodiment of this application;

FIG. 6A, FIG. 6B, and FIG. 6C are a schematic flowchart 3 of a datatransmission method according to an embodiment of this application;

FIG. 7A, FIG. 7B, and FIG. 7C are a schematic flowchart 4 of a datatransmission method according to an embodiment of this application;

FIG. 8 is a schematic flowchart of an MLAN identity configuration methodaccording to an embodiment of this application; and

FIG. 9 is a schematic structural diagram of a first user plane functionentity according to an embodiment of this application.

DESCRIPTION OF EMBODIMENTS

For ease of understanding technical solutions in the embodiments of thisapplication, the following first briefly describes technologies relatedto this application.

Identity (ID) of an MLAN.

An identity of an MLAN is used to identify an MLAN instance. If MLANsare classified by scenario, for example, an enterprise or vehicle toeverything communication (V2X), a type of MLAN scenario may beidentified by using an MLAN type or a data network name (DNN). To bespecific, an identity of an MLAN includes a scenario identifier and anMLAN number, and an MLAN instance in a type of MLAN scenario can beuniquely identified with reference to a scenario identifier and an MLANnumber. If DNN resources are sufficient, and the MLANs do not need to beclassified by scenario, an identity of an MLAN corresponds to a uniqueMLAN instance in a DNN. Whether the MLANs are classified by scenario isnot specifically limited in the following embodiments of thisapplication, and an example in which an identity of an MLAN can uniquelyidentify an MLAN instance is used for description. A general descriptionis provided herein, and details are not described below again.

In addition, in the embodiments of this application, the identity of theMLAN may be corresponding to a specific service area, or may beavailable a globally. A service range corresponding to the identity ofthe MLAN is not specifically limited in the embodiments of thisapplication.

Tunnel.

Tunnels include a next generation (N) interface 3 (N3) tunnel and an Ninterface 9 (N9) tunnel. The N3 tunnel is a tunnel between an accessdevice (for example, a base station) and a UPF entity. The N9 tunnel isa tunnel between UPF entities. Generally, the N3 tunnel is a tunnel at asession granularity, and the N9 tunnel may be a tunnel at a sessiongranularity, or a tunnel at a device granularity.

The tunnel at a session granularity is a tunnel resource established forone session, and the tunnel is used for only one session. One tunnel ata session granularity includes only one routing rule, and only therouting rule can be corresponding to the tunnel for forwarding data. Inaddition, a lifecycle of the tunnel at a session granularity is alifecycle of one session. To be specific, when the session disappears oris released, the tunnel at a session granularity also needs to bereleased.

The tunnel at a device granularity is a tunnel resource established forone or more sessions, and the tunnel may be used for one or moresessions. One tunnel at a device granularity may include one or morerouting rules, and each of the one or more routing rules can becorresponding to the tunnel for forwarding data. In addition, alifecycle of the tunnel at a device granularity is a lifecycle of aplurality of sessions corresponding to the tunnel. To be specific,assuming that the tunnel at a device granularity corresponds to Msessions, when the first M−1 sessions in the plurality of sessionscorresponding to the tunnel disappear or are released, only routingrules corresponding to the corresponding sessions are released; and thetunnel at a device granularity can be released only when an M^(th)session in the plurality of sessions corresponding to the tunneldisappears or is released. Certainly, when the M^(th) session in theplurality of sessions corresponding to the tunnel disappears or isreleased, the tunnel at a device granularity may be alternativelyretained, so that the tunnel does not need to be re-establishedsubsequently. This is not specifically limited in the embodiments ofthis application.

A session in the embodiments of this application may be, for example, apacket data unit (PDU) session. A general description is providedherein, and details are not described below again.

A tunnel in the following embodiments of this application not onlyrelates to the N3 tunnel, but also relates to the N9 tunnel. A generaldescription is provided herein, and details are not described belowagain.

Path Information.

Path information in the embodiments of this application includesinformation about an uplink path corresponding to a first terminal,information about a downlink path corresponding to the first terminal,information about an uplink path corresponding to a second terminal,information about a downlink path corresponding to the second terminal,path information of a first user plane function entity, and pathinformation of a second user plane function entity. The informationabout the uplink path corresponding to the first terminal is used todetermine the uplink path corresponding to the first terminal, and theinformation about the downlink path corresponding to the first terminalis used to determine the downlink path corresponding to the firstterminal. The information about the uplink path corresponding to thesecond terminal is used to determine the uplink path corresponding tothe second terminal, and the information about the downlink pathcorresponding to the second terminal is used to determine the downlinkpath corresponding to the second terminal. The path information of thefirst user plane function entity is used to determine the first userplane function entity, and the path information of the second user planefunction entity is used to determine the second user plane functionentity. In addition, the information about the uplink path correspondingto the first terminal and the information about the downlink pathcorresponding to the first terminal may be further used to determine atunnel that is established between a first access device and the firstuser plane function entity for the first terminal. The information aboutthe uplink path corresponding to the second terminal and the informationabout the downlink path corresponding to the second terminal may befurther used to determine a tunnel that is established between a secondaccess device and the second user plane function entity for the secondterminal. The path information of the first user plane function entityand the path information of the second user plane function entity may befurther used to determine a tunnel established between the first userplane function entity and the second user plane function entity.

In the embodiments of this application, an example in which the firstuser plane function entity and the second user plane function entity aredifferent user plane function entities is used for description.Certainly, the first user plane function entity and the second userplane function entity may be alternatively a same user plane functionentity. This is not specifically limited in the embodiments of thisapplication.

In the embodiments of this application, the information about the uplinkpath corresponding to the first terminal may include a tunnel identifierof the first UPF entity allocated for the first terminal, theinformation about the downlink path corresponding to the first terminalmay include a tunnel identifier of the first access device allocated forthe first terminal, the information about the uplink path correspondingto the second terminal may include a tunnel identifier of the second UPFentity allocated for the second terminal, the information about thedownlink path corresponding to the second terminal may include a tunnelidentifier of the second access device allocated for the secondterminal, the path information of the first user plane function entityincludes the tunnel identifier of the first user plane function entity,and the path information of the second user plane function entityincludes the tunnel identifier of the second user plane function entity.The tunnel identifier may be, for example, a tunnel endpoint identifier(TEID). This is not specifically limited in the embodiments of thisapplication.

Certainly, the information about the uplink path corresponding to thefirst terminal, the information about the downlink path corresponding tothe first terminal, the information about the uplink path correspondingto the second terminal, the information about the downlink pathcorresponding to the second terminal, the path information of the firstuser plane function entity, and the path information of the second userplane function entity may further include other information. Forexample, the information about the uplink path corresponding to thefirst terminal may further include an IP address of the first user planefunction entity, the information about the downlink path correspondingto the first terminal may further include an IP address of the firstaccess device, the information about the uplink path corresponding tothe second terminal may further include an IP address of the second userplane function entity, the information about the downlink pathcorresponding to the second terminal may further include an IP addressof the second access device, the path information of the first userplane function entity may further include the IP address of the firstuser plane function entity, and the path information of the second userplane function entity may further include the IP address of the seconduser plane function entity. This is not specifically limited in theembodiments of this application.

The following describes the technical solutions in the embodiments ofthis application with reference to the accompanying drawings in theembodiments of this application. In descriptions of this application,“/” means “or” unless otherwise specified. For example, A/B mayrepresent A or B. In this specification, “and/or” describes only anassociation relationship for describing associated objects andrepresents that three relationships may exist. For example, A and/or Bmay represent the following three cases: only A exists, both A and Bexist, and only B exists. In addition, in descriptions of thisapplication, the term “a plurality of” means two or more than two unlessotherwise specified. In addition, to clearly describe the technicalsolutions in the embodiments of this application, terms such as “first”and “second” are used in the embodiments of this application todistinguish between same items or similar items that have basically thesame functions or purposes. A person skilled in the art may understandthat the terms such as “first” and “second” are not intended to limit aquantity or an execution sequence; and the terms such as “first” and“second” do not indicate a definite difference.

A network architecture and a service scenario described in theembodiments of this application are intended to describe the technicalsolutions in the embodiments of this application more clearly, and donot constitute a limitation on the technical solutions provided in theembodiments of this application. A person of ordinary skill in the artmay know that as the network architecture evolves and new servicescenarios emerge, the technical solutions provided in the embodiments ofthis application are further applicable to a similar technical problem.

FIG. 1 is a schematic structural diagram of a data transmission system10 according to an embodiment of this application. The data transmissionsystem 10 includes a first user plane function entity 101, a second userplane function entity 102, a first access device 103, and a secondaccess device 104.

A first terminal communicates with the first user plane function entity101 by using the first access device 103. A second terminal communicateswith the second user plane function entity 102 by using the secondaccess device 104.

The first user plane function entity 101 is configured to receive a datapacket from the first terminal through an uplink path corresponding tothe first terminal. The data packet carries addressing information of asecond terminal. The first user plane function entity 101 is a userplane function entity currently accessed by the first terminal.

The first user plane function entity 101 is further configured todetermine path information of the second user plane function entity 102based on information about the uplink path corresponding to the firstterminal and the addressing information of the second terminal. Thesecond user plane function entity 102 is a user plane function entitycurrently accessed by the second terminal.

The first user plane function entity 101 is further configured to sendthe data packet to the second user plane function entity 102 based onthe path information of the second user plane function entity 102.

The second user plane function entity 102 is further configured toreceive the data packet from the first user plane function entity 101,and send the data packet to the second terminal through a downlink pathcorresponding to the second terminal.

It should be noted that in this embodiment of this application, anexample in which the first user plane function entity 101 and the seconduser plane function entity 102 are different user plane functionentities is used for description. Certainly, the first user planefunction entity 101 and the second user plane function entity 102 may bealternatively a same user plane function entity. This is notspecifically limited in this embodiment of this application.

Optionally, in this embodiment of this application, the first user planefunction entity 101 may directly communicate with the first accessdevice 103, or may communicate with the first access device 103 throughforwarding by another device. The second user plane function entity 102may directly communicate with the second access device 104, or maycommunicate with the second access device 104 through forwarding byanother device. This is not specifically limited in this embodiment ofthis application.

Based on the data transmission system provided in this embodiment ofthis application, after receiving the data packet from the firstterminal through the uplink path corresponding to the first terminal,the first user plane function entity may determine the path informationof the second user plane function entity based on the information aboutthe uplink path corresponding to the first terminal and the addressinginformation of the second terminal, and may further send the data packetto the second user plane function entity based on the path informationof the second user plane function entity; and the second user planefunction entity sends the data packet to the second terminal through thedownlink path corresponding to the second terminal. This can implementlocal interaction between the two terminals when the two terminals areserved by different user plane function entities.

Optionally, the data transmission system 10 may be applied to a 5thgeneration (5G) network and other future networks. This is notspecifically limited in this embodiment of this application.

If the data transmission system 10 is applied to the 5G network, asshown in FIG. 2, a network element or an entity corresponding to thefirst user plane function entity 101 may be a first UPF entity, anetwork element or an entity corresponding to the second user planefunction entity 102 may be a second UPF entity, a network element or anentity corresponding to the first access device 103 may be a firstaccess network (AN) device, and a network element or an entitycorresponding to the second access device 104 may be a second AN device.The first terminal accesses a network by using the first AN device. Thesecond terminal accesses the network by using the second AN device. Thefirst AN device communicates with the first UPF entity through an N3interface (N3). The second AN device communicates with the second UPFentity through N3.

In addition, as shown in FIG. 2, the 5G network may further include anaccess and mobility management function (AMF) entity, a sessionmanagement function (SMF) entity, a unified data management (UDM)entity, an authentication server function (AUSF) entity, a policycontrol function (PCF) entity, and the like. This is not specificallylimited in this embodiment of this application.

Both the first terminal and the second terminal communicate with the AMFentity through an N1 interface (N1). Both the first AN device and thesecond AN device communicate with the AMF entity through an N2 interface(N2). The AMF entity communicates with the AUSF entity through an N12interface (N12). The AMF entity communicates with the UDM entity throughan N8 interface (N8). The AMF entity communicates with the SMF entitythrough an N11 interface (N11). The AMF entity communicates with the PCFentity through an N15 interface (N15). The AUSF entity communicates withthe UDM entity through an N13 interface (N13). The SMF entitycommunicates with the first UPF entity and the second UPF entity throughan N4 interface (N4).

Optionally, an example in which the first AN device and the second ANdevice are communicatively connected to a same AMF entity is used fordescription in FIG. 2. Certainly, the first AN device and the second ANdevice may be alternatively connected to different AMF entities. This isnot specifically limited in this embodiment of this application.

Optionally, an example in which the first UPF entity and the second UPFentity are communicatively connected to a same SMF entity is used fordescription in FIG. 2. Certainly, the first UPF entity and the secondUPF entity may be alternatively connected to different SMF entities.This is not specifically limited in this embodiment of this application.

It should be noted that names of the interfaces between the networkelements in FIG. 2 are merely examples, and the interfaces may haveother names during specific implementation. This is not specificallylimited in this embodiment of this application.

It should be noted that the first AN device, the second AN device, theAMF entity, the SMF entity, the AUSF entity, the UDM entity, the firstUPF entity, the second UPF entity, the PCF entity, and the like in FIG.2 are merely names, and the names constitute no limitation on thedevices. In the 5G network and other future networks, network elementsor entities corresponding to the first AN device, the second AN device,the AMF entity, the SMF entity, the AUSF entity, the UDM entity, thefirst UPF entity, the second UPF entity, and the PCF entity may haveother names. This is not specifically limited in this embodiment of thisapplication. For example, the UDM entity may be replaced with a homesubscriber server (HSS), a user subscription database (USD), a databaseentity, or the like. A general description is provided herein, anddetails are not described below again.

Optionally, the terminal in this embodiment of this application mayinclude various handheld devices, vehicle-mounted devices, wearabledevices, and computing devices that have a wireless communicationfunction, or other processing devices connected to a wireless modem. Theterminal may further include a subscriber unit, a cellular phone, asmartphone, a wireless data card, a personal digital assistant (PDA)computer, a tablet computer, a wireless modem, a handheld device, alaptop computer, a cordless phone or a wireless local loop (WLL)station, a machine type communication (MTC) terminal, user equipment(UE), a mobile station (MS), a terminal device, and the like. For easeof description, the devices mentioned above are collectively referred toas a terminal in this application.

Optionally, the access device in this embodiment of this application isa device that accesses a core network, for example, a base station, abroadband network gateway (BNG), an aggregation switch, or a non-3rdgeneration partnership project (3GPP) access device. The base stationmay include base stations in various forms, such as a macro basestation, a micro base station (also referred to as a small cell), arelay station, and an access point.

Optionally, in this embodiment of this application, the first UPF entityhas a function of the first user plane function entity shown in FIG. 1,the second UPF entity has a function of the second user plane functionentity shown in FIG. 1, and the first UPF entity and the second UPFentity may further implement user plane functions of a serving gateway(SGW) and a packet data network gateway (PGW). In addition, the firstUPF entity and the second UPF entity may be alternativelysoftware-defined networking (SDN) switch. This is not specificallylimited in this embodiment of this application.

Optionally, the AUSF entity in this embodiment of this application isconfigured to authenticate the terminal based on subscription data ofthe terminal.

Optionally, the UDM entity in this embodiment of this application isconfigured to store subscription data. In addition, the UDM entityfurther includes functions such as authentication, user identifierprocessing, and subscription management. This is not specificallylimited in this embodiment of this application.

Optionally, the PCF entity in this embodiment of this applicationprovides a policy rule, and supports a function related to a policy suchas unified policy architecture management network behavior.

Optionally, the first user plane function entity and the second userplane function entity in FIG. 1 may be implemented by one physicaldevice, may be jointly implemented by a plurality of physical devices,or may be a logical function module in a physical device. This is notspecifically limited in this embodiment of this application.

For example, the first user plane function entity and the second userplane function entity in FIG. 1 may be implemented by using acommunications device in FIG. 3. FIG. 3 is a schematic diagram of ahardware structure of a communications device according to an embodimentof this application. The communications device 300 includes at least oneprocessor 301, a communications line 302, a memory 303, and at least onecommunications interface 304.

The processor 301 may be a general-purpose central processing unit(CPU), a microprocessor, an application-specific integrated circuit(ASIC), or one or more integrated circuits configured to control programexecution in the solutions in this application.

The communications line 302 may include a path for transmittinginformation between the foregoing components.

The communications interface 304, which uses any apparatus such as atransceiver, is configured to communicate with another device or acommunications network, such as Ethernet, a radio access network (RAN),or a wireless local area network (WLAN).

The memory 303 may be a read-only memory (ROM) or another type of staticstorage device capable of storing static information and instructions,or a random access memory (RAM) or another type of dynamic storagedevice capable of storing information and instructions, or may be anelectrically erasable programmable read-only memory (EEPROM), a compactdisc read-only memory (CD-ROM) or another compact disc storage, anoptical disc storage (including a compressed optical disc, a laser disc,an optical disc, a digital versatile disc, a Blu-ray optical disc, andthe like), a magnetic disk storage medium or another magnetic storagedevice, or any other medium that is capable of carrying or storingexpected program code in a form of instructions or data structures andthat can be accessed by a computer, but is not limited thereto. Thememory may exist independently and is connected to the processor byusing the communications line 302. Alternatively, the memory may beintegrated with the processor.

The memory 303 is configured to store a computer executable instructionfor implementing the solutions of this application, and the computerexecutable instruction is executed under control of the processor 301.The processor 301 is configured to execute the computer executableinstruction stored in the memory 303, to implement a data transmissionmethod provided in the following embodiments of this application.

Optionally, the computer executable instruction in this embodiment ofthis application may also be referred to as application program code.This is not specifically limited in this embodiment of this application.

During specific implementation, in an embodiment, the processor 301 mayinclude one or more CPUs, for example, a CPU 0 and a CPU 1 in FIG. 3.

During specific implementation, in an embodiment, the communicationsdevice 300 may include a plurality of processors, for example, aprocessor 301 and a processor 308 in FIG. 3. Each of these processorsmay be a single-core (single-CPU) processor, or may be a multi-core(multi-CPU) processor. The processor herein may be one or more devices,circuits, and/or processing cores configured to process data (forexample, a computer program instruction).

During specific implementation, in an embodiment, the communicationsdevice 300 may further include an output device 305 and an input device306. The output device 305 communicates with the processor 301, and maydisplay information in a plurality of manners. For example, the outputdevice 305 may be a liquid crystal display (LCD), a light emitting diode(LED) display device, a cathode ray tube (CRT) display device, or aprojector. The input device 306 communicates with the processor 301, andmay receive users' input in a plurality of manners. For example, theinput device 306 may be a mouse cursor, a keyboard, a touchscreendevice, or a sensing device.

The communications device 300 may be a general-purpose device or adedicated device. During specific implementation, the communicationsdevice 300 may be a desktop computer, a portable computer, a networkserver, a personal digital assistant (PDA), a mobile phone, a tabletcomputer, a wireless terminal device, an embedded device, or a devicewith a structure similar to that in FIG. 3. A type of the communicationsdevice 300 is not limited in this embodiment of this application.

The following describes in detail a data transmission method provided inthe embodiments of this application with reference to FIG. 1 to FIG. 3.

First, two typical scenarios that are applicable to the embodiments ofthis application are provided as follows.

Scenario 1, two terminals that access a same MLAN are served bydifferent user plane function entities. For example, a first terminal isserved by a first user plane function entity, and a second terminal isserved by a second user plane function entity.

Scenario 2, before a terminal is handed over, two terminals that accessa same MLAN are served by a same user plane function entity. After theterminal is handed over, the two terminals that access the same MLAN areserved by different user plane function entities. For example, both afirst terminal and a second terminal are originally served by a firstuser plane function entity. During communication between the firstterminal and the second terminal, the second terminal moves, so that thesecond terminal is handed over to a second user plane function entity,and is served by the second user plane function entity. In this case,the first terminal and the second terminal are served by different userplane function entities.

Then, for example, the data transmission system shown in FIG. 1 isapplied to the 5G network shown in FIG. 2. For the scenario 1, a datatransmission method provided in an embodiment of this application may beshown in FIG. 4A to FIG. 4C, and includes the following steps.

S401 a. A first terminal sends an MLAN session establishment request toan AMF entity, so that the AMF entity receives the MLAN sessionestablishment request from the first terminal, where the MLAN sessionestablishment request carries an identity of an MLAN to which the firstterminal subscribes.

A process of configuring the identity of the MLAN to which the firstterminal subscribes is described in the following embodiment. Detailsare not described herein.

Optionally, in this embodiment of this application, if the identity ofthe MLAN to which the first terminal subscribes corresponds to aspecific service area, information about the specific service areacorresponding to the identity of the MLAN is also configured on thefirst terminal. In this case, the first terminal may send, based on theinformation about the specific service area corresponding to theidentity of the MLAN, the MLAN session establishment request to the AMFentity in the specific service area corresponding to the identity of theMLAN. Certainly, if the first terminal sends the MLAN sessionestablishment request to the AMF entity beyond the specific service areacorresponding to the identity of the MLAN, the AMF entity or an SMFentity may reject, after determining that a current location of thefirst terminal is not within the specific service area corresponding tothe identity of the MLAN, the MLAN session establishment request sent bythe first terminal. This is not specifically limited in this embodimentof this application. In this embodiment of this application, that thefirst terminal initiates a normal MLAN session establishment procedureis merely used as an example for description. To be specific, when theidentity of the MLAN to which the first terminal subscribes is availableglobally, the first terminal sends the MLAN session establishmentrequest to the AMF entity. Alternatively, when the identity of the MLANto which the first terminal subscribes corresponds to the specificservice area, the first terminal sends the MLAN session establishmentrequest in the specific service area corresponding to the identity ofthe MLAN to which the first terminal subscribes. A general descriptionis provided herein, and details are not described below again.

S402 a. The AMF entity selects the SMF entity.

For a specific manner in which the AMF entity selects the SMF entity,refer to an existing solution. Details are not described herein.

S403 a. The AMF entity sends the MLAN session establishment request tothe SMF entity, so that the SMF entity receives the MLAN sessionestablishment request from the AMF entity.

S404 a. The SMF entity selects a first UPF entity.

For a specific manner in which the SMF entity selects the first UPFentity, refer to an existing solution. Details are not described herein.

Optionally, in this embodiment of this application, the SMF entity mayfurther obtain, from a UDM entity, the identity of the MLAN to which thefirst terminal subscribes, and determine that the identity of the MLANcarried in the MLAN session establishment request is the same as theidentity of the MLAN to which the first terminal subscribes. If theidentity of the MLAN carried in the MLAN session establishment requestis the same as the identity of the MLAN to which the first terminalsubscribes, it may be determined that the identity of the MLAN carriedin the MLAN session establishment request is the identity of the MLAN towhich the first terminal subscribes, and a subsequent operations may beperformed. If the identity of the MLAN carried in the MLAN sessionestablishment request is different from the identity of the MLAN towhich the first terminal subscribes, it may be determined that theidentity of the MLAN carried in the MLAN session establishment requestis not the identity of the MLAN to which the first terminal subscribes,and a procedure ends. This is not specifically limited in thisembodiment of this application.

S405 a. The SMF entity sends an N4 session message 1 to the first UPFentity, so that the first UPF entity receives the N4 session message 1from the SMF entity, where the N4 session message 1 carries the identityof the MLAN to which the first terminal subscribes and first-terminaladdressing information.

Optionally, in this embodiment of this application, the first-terminaladdressing information may be an internet protocol (IP) address or amedia access control (MAC) address of the first terminal. This is notspecifically limited in this embodiment of this application.

If the first-terminal addressing information is the IP address, the SMFentity may obtain the IP address of the first terminal in the followingmanner. An IP address pool corresponding to an identity of each MLAN isconfigured on the SMF entity, and a correspondence between the identityof the MLAN and information about the IP address pool is established.When the first terminal establishes an MLAN session, a corresponding IPaddress pool may be determined based on the identity of the MLAN towhich the first terminal subscribes and the correspondence, and the IPaddress from the IP address pool is allocated for the first terminal.

If the first-terminal addressing information is the MAC address, the SMFentity may obtain the MAC address of the first terminal in the followingmanner. The MLAN session establishment request that is sent by the firstterminal to the SMF entity by using the AMF entity carries the MACaddress of the first terminal, so that the SMF entity may obtain the MACaddress from the MLAN session establishment request.

Certainly, the SMF entity may alternatively obtain the IP address or theMAC address of the first terminal in another manner. For example, theMAC address of the first terminal is carried in a dynamic hostconfiguration protocol (DHCP) procedure, or the IP address of the firstterminal is allocated in the DHCP procedure. This is not specificallylimited in this embodiment of this application.

S406 a. The first UPF entity establishes a correspondence between theidentity of the MLAN to which the first terminal subscribes andinformation about an uplink path corresponding to the first terminal,and a correspondence between the identity of the MLAN to which the firstterminal subscribes and path information of the first UPF entity.

Optionally, in this embodiment of this application, the informationabout the uplink path corresponding to the first terminal may beallocated by the SMF entity, or may be allocated by the first UPFentity. This is not specifically limited in this embodiment of thisapplication. If the information about the uplink path corresponding tothe first terminal is allocated by the SMF entity, the N4 sessionmessage 1 in step S405 a may further carry the information about theuplink path corresponding to the first terminal. A general descriptionis provided herein, and details are not described below again.

For ease of description, in this embodiment of this application, thecorrespondence between the identity of the MLAN to which the firstterminal subscribes and the information about the uplink pathcorresponding to the first terminal may be denoted as acorrespondence 1. A general description is provided herein, and detailsare not described below again. The correspondence 1 may be shown inTable 1.

TABLE 1 Identity of the MLAN to which the Information about the uplinkpath first terminal subscribes corresponding to the first terminal

Optionally, in this embodiment of this application, the path informationof the first UPF entity may be allocated by the SMF entity, or may beallocated by the first UPF entity. This is not specifically limited inthis embodiment of this application. If the path information of thefirst UPF entity is allocated by the SMF entity, the N4 session message1 in step S405 a may further carry the path information of the first UPFentity. A general description is provided herein, and details are notdescribed below again.

For ease of description, in this embodiment of this application, thecorrespondence between the identity of the MLAN to which the firstterminal subscribes and the path information of the first UPF entity maybe denoted as a correspondence 2. A general description is providedherein, and details are not described below again. The correspondence 2may be shown in Table 2.

TABLE 2 Identity of the MLAN to which the Path information of the firstUPF first terminal subscribes entity

Optionally, the correspondence 1 and the correspondence 2 may beestablished by the SMF entity and then sent to the first UPF entity.This is not specifically limited in this embodiment of this application.

Optionally, in this embodiment of this application, an N9 tunnel betweenthe first UPF entity and a second UPF entity may be established beforethe MLAN session is established, or may be established in a process ofestablishing the MLAN session. This is not specifically limited in thisembodiment of this application.

S407 a. The first UPF entity sends information about the uplink pathcorresponding to the first terminal to a first AN device, so that thefirst AN device receives the information about the uplink pathcorresponding to the first terminal from the first UPF entity.

S408 a. The first AN device sends information about a downlink pathcorresponding to the first terminal to the first UPF entity, so that thefirst UPF entity receives the information about the downlink pathcorresponding to the first terminal from the first AN device.

Optionally, in this embodiment of this application, the informationabout the downlink path corresponding to the first terminal may beallocated by the SMF entity, or may be allocated by the first AN device.This is not specifically limited in this embodiment of this application.

S409 a. The first UPF entity establishes a correspondence between theidentity of the MLAN to which the first terminal subscribes, theinformation about the downlink path corresponding to the first terminal,and the first-terminal addressing information.

For ease of description, in this embodiment of this application, thecorrespondence between the identity of the MLAN to which the firstterminal subscribes, the information about the downlink pathcorresponding to the first terminal, and the first-terminal addressinginformation may be denoted as a correspondence 3. A general descriptionis provided herein, and details are not described below again. Thecorrespondence 3 may be shown in Table 3.

TABLE 3 Identity of the MLAN to Information about the First-terminalwhich the first terminal downlink path corresponding addressingsubscribes to the first terminal information

Optionally, the correspondence 3 may be established by the SMF entityand then sent to the first UPF entity. This is not specifically limitedin this embodiment of this application.

S410 a. The SMF entity sends an N4 session message 2 to the second UPFentity, so that the second UPF entity receives the N4 session message 2from the SMF entity, where the N4 session message 2 carries the identityof the MLAN to which the first terminal subscribes, the first-terminaladdressing information, and the path information of the first UPFentity.

To be specific, in this embodiment of this application, in the processof establishing the MLAN session, if the SMF entity determines thatthere is a cross-UPF entity scenario in the current MLAN, for example,if the MLAN to which the first terminal subscribes includes not only thefirst UPF entity, but also includes the second UPF entity, the SMFentity may establish the N9 tunnel between the first UPF entity and thesecond UPF entity.

It should be noted that in this embodiment of this application, the N9tunnel between the first UPF entity and the second UPF entity is basedon an MLAN granularity, and is irrelevant to a terminal. In other words,any two UPFs in the same MLAN share one tunnel.

S411. The second UPF entity establishes a correspondence between theidentity of the MLAN to which the first terminal subscribes, thefirst-terminal addressing information, and the path information of thefirst UPF entity.

For ease of description, in this embodiment of this application, thecorrespondence between the identity of the MLAN to which the firstterminal subscribes, the first-terminal addressing information, and thepath information of the first UPF entity may be denoted as acorrespondence 4. A general description is provided herein, and detailsare not described below again. The correspondence 4 may be shown inTable 4.

TABLE 4 Identity of the MLAN to Path information of the First-terminalwhich the first terminal first UPF entity addressing subscribesinformation

Optionally, the correspondence 4 may be established by the SMF entityand then sent to the second UPF entity. This is not specifically limitedin this embodiment of this application.

Optionally, in this embodiment of this application, the N9 tunnelbetween the first UPF entity and the second UPF entity may beestablished before the MLAN session is established, or may beestablished in the process of establishing the MLAN session. This is notspecifically limited in this embodiment of this application.

Steps S401 b to S411 b are similar to steps S401 a to S411 a.Differences lie in steps S401 b to S411 b, the first terminal in stepsS401 a to S409 a is replaced with a second terminal, the first AN devicein steps S401 a to S409 a is replaced with a second AN device, and thefirst UPF entity in steps S401 a to S409 a is replaced with the secondUPF entity. For details, refer to steps S401 a to S411 a. Details arenot described herein again.

In step S406 b, the second UPF entity establishes a correspondencebetween the identity of the MLAN to which the second terminalsubscribes, and information about an uplink path corresponding to thesecond terminal, and the correspondence may be denoted as acorrespondence 5. A general description is provided herein, and detailsare not described below again. The correspondence 5 may be shown inTable 5.

TABLE 5 Identity of the MLAN to which the Information about the uplinkpath second terminal subscribes corresponding to the second terminal

In step S406 b, the second UPF entity establishes a correspondencebetween the identity of the MLAN to which the second terminal subscribesand path information of the second UPF entity, and the correspondencemay be denoted as a correspondence 6. A general description is providedherein, and details are not described below again. The correspondence 6may be shown in Table 6.

TABLE 6 Identity of the MLAN to which Path information of the second UPFthe second terminal subscribes entity

In step S409 b, the second UPF entity establishes a correspondencebetween the identity of the MLAN to which the second terminalsubscribes, information about a downlink path corresponding to thesecond terminal, and addressing information of a second terminal, andthe correspondence may be denoted as a correspondence 7. A generaldescription is provided herein, and details are not described belowagain. The correspondence 7 may be shown in Table 7.

TABLE 7 Identity of the MLAN Information about the Addressing to whichthe second downlink path corresponding information of a terminalsubscribes to the second terminal second terminal

In step S411 b, the first UPF entity establishes a correspondencebetween the identity of the MLAN to which the second terminalsubscribes, the path information of the second UPF entity, and theaddressing information of the second terminal, and the correspondencemay be denoted as a correspondence 8. A general description is providedherein, and details are not described below again. The correspondence 8may be shown in Table 8.

TABLE 8 Identity of the MLAN to which Path information Addressing thesecond terminal subscribes of the second UPF information of the entitysecond terminal

Optionally, the correspondence 5, the correspondence 6, and thecorrespondence 7 may be established by the SMF entity and then sent tothe second UPF entity. This is not specifically limited in thisembodiment of this application.

Optionally, the correspondence 8 may be established by the SMF entityand then sent to the first UPF entity. This is not specifically limitedin this embodiment of this application.

Optionally, in this embodiment of this application, the N9 tunnelbetween the first UPF entity and the second UPF entity may beestablished before the MLAN session is established, or may bedynamically established in the process of establishing the MLAN session.This is not specifically limited in this embodiment of this application.

Optionally, to save a storage resource, Table 1, Table 2, Table 3, andTable 8 may be combined, Table 4 to Table 7 may be combined, andcombination results are shown in Table 9 and Table 10, respectively.

TABLE 9 Identity of Information Information First-terminal Path Path theMLAN about the about the addressing information information to whichuplink path downlink path information of the first of the the firstcorresponding corresponding UPF entity second UPF terminal to the firstto the first entity subscribes terminal terminal

TABLE 10 Identity of Information Information Addressing Path Path theMLAN about the about the information information information to whichuplink path downlink path of the of the of the first the secondcorresponding corresponding second second UPF UPF entity terminal to thesecond to the second terminal entity subscribes terminal terminal

Optionally, if the identity of the MLAN to which the first terminalsubscribes is the same as the identity of the MLAN to which the secondterminal subscribes, Table 9 and Table 10 may be combined to furthersave the resource, and a result is shown in Table 11.

TABLE 11 Identity Information Information Addressing Path Path of anabout an about a information information information MLAN uplink pathdownlink path of a UPF entity of a UPF entity Identity of InformationInformation First-terminal Path Path the MLAN about the about theaddressing information information to which uplink path downlink pathinformation of the of the first the first corresponding correspondingsecond UPF entity terminal/ to the first to the first UPF entity secondterminal terminal terminal Information Information Addressing Path Pathsubscribes about the about the information information informationuplink path downlink path of the of the of the first correspondingcorresponding second second UPF entity to the second to the secondterminal UPF entity terminal terminal

To be specific, when the identity of the MLAN to which a plurality ofterminals subscribe is the same, the identity of the MLAN may berecorded as common information. For example, an establishedcorrespondence between an identity of an MLAN, information about anuplink path, information about a downlink path, addressing information,and path information of a UPF entity may be shown in Table 12.

TABLE 12 Identity Information Information Addressing Path Path of anabout an about a information information information MLAN uplink pathdownlink path of a UPF of a UPF entity entity a Information InformationFirst-terminal Path Path about an about a addressing informationinformation uplink path downlink path information of a first of a secondcorresponding corresponding UPF entity UPF entity Identity InformationInformation Addressing Path Path of an about an about a informationinformation information MLAN uplink path downlink path of a UPF of a UPFto a first to the first entity entity terminal terminal Path informationof a third UPF entity Information Information Addressing Path Path aboutan about a information of information information uplink path downlinkpath a second of the of the first corresponding corresponding terminalsecond UPF entity to a second to the second UPF entity terminal terminalInformation Information Third-terminal Path Path about an about aaddressing information information uplink path downlink path informationof the third of the first corresponding corresponding UPF entity UPFentity to a third to the third terminal terminal . . . . . . . . . . . .. . . b Information Information Fourth-terminal Path Path about an abouta addressing information information uplink path downlink pathinformation of the third of a fourth corresponding corresponding UPFentity UPF entity to a fourth to the fourth terminal terminal IdentityInformation Information Addressing Path Path of an about an about ainformation information information MLAN uplink path downlink path of aUPF of a UPF entity entity Information Information Fifth-terminal PathPath about an about a addressing information information uplink pathdownlink path information of the third of a fifth correspondingcorresponding UPF entity UPF entity to a fifth to the fifth terminalterminal . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . ..

Certainly, there may be another combination manner or simplified mannerfor the foregoing correspondences. This is not specifically limited inthis embodiment of this application. Furthermore, in addition to beingrepresented in a table form, the foregoing correspondences may berepresented in another form, for example, in a text form or a sessioncontext form. This is not specifically limited in this embodiment ofthis application.

It should be noted that the correspondence between a terminal and a UPFentity in Table 12 is merely used as an example for description. Forexample, a terminal 1 may be further served by a UPF entity 6. This isnot specifically limited in this embodiment of this application.

Optionally, for example, the identity of the MLAN to which the firstterminal subscribes is the same as the identity of the MLAN to which thesecond terminal subscribes, and the first terminal sends a data packet 1to the second terminal. In this case, the data transmission methodprovided in this embodiment of this application further includes thefollowing steps S412 to S418.

S412. The first terminal sends the data packet 1 to the first UPF entitythrough the uplink path corresponding to the first terminal, so that thefirst UPF entity receives the data packet 1 from the first terminalthrough the uplink path corresponding to the first terminal, where thedata packet 1 carries the addressing information of the second terminal,and the addressing information of the second terminal is used asdestination addressing information.

Optionally, the data packet 1 may further carry the first-terminaladdressing information that is used as source addressing information.This is not specifically limited in this embodiment of this application.

S413. The first UPF entity determines, based on the information aboutthe uplink path corresponding to the first terminal, the identity of theMLAN to which the first terminal subscribes.

The first UPF entity may determine, based on the information about theuplink path corresponding to the first terminal and the correspondence1, the identity of the MLAN to which the first terminal subscribes.

For example, the first UPF entity may search Table 1, Table 9, or Table11 based on the information about the uplink path corresponding to thefirst terminal to obtain the identity of the MLAN to which the firstterminal subscribes.

S414. The first UPF entity determines the path information of the secondUPF entity based on the identity of the MLAN to which the first terminalsubscribes and the addressing information of the second terminal andwith reference to the correspondence 8.

The first UPF entity may determine the path information of the secondUPF entity based on the identity of the MLAN to which the first terminalsubscribes, the addressing information of the second terminal, and thecorrespondence 8.

For example, the first UPF entity may search Table 8, Table 9, Table 11,or Table 12 based on the identity of the MLAN to which the firstterminal subscribes and the addressing information of the secondterminal to obtain the path information of the second UPF entity.

Optionally, if the first UPF entity may determine the downlink pathcorresponding to the second terminal based on the identity of the MLANto which the first terminal subscribes and the addressing information ofthe second terminal and with reference to the correspondence 3, itindicates that the first terminal and the second terminal are served bythe same UPF entity. In this case, the first UPF entity may send thedata packet 1 to the second terminal through the downlink pathcorresponding to the second terminal. This is not specifically limitedin this embodiment of this application.

S415. The first UPF entity sends the data packet 1 to the second UPFentity based on the path information of the second UPF entity, so thatthe second UPF entity receives the data packet 1 from the first UPFentity.

S416. The second UPF entity determines, based on the path information ofthe second UPF entity, the identity of the MLAN to which the secondterminal subscribes.

The second UPF entity may determine, based on the path information ofthe second UPF entity and the correspondence 6, the identity of the MLANto which the second terminal subscribes.

For example, the second UPF entity may search Table 6, Table 10, Table11, or Table 12 based on the path information of the second UPF entityto obtain the identity of the MLAN to which the second terminalsubscribes.

S417. The second UPF entity determines, based on the identity of theMLAN to which the second terminal subscribes and the addressinginformation of the second terminal, the downlink path corresponding tothe second terminal.

The second UPF entity may determine, based on the identity of the MLANto which the second terminal subscribes, the addressing information ofthe second terminal, and the correspondence 7, the downlink pathcorresponding to the second terminal.

For example, the second UPF entity may search Table 7, Table 10, Table11, or Table 12 based on the identity of the MLAN to which the secondterminal subscribes and the addressing information of the secondterminal to determine the downlink path corresponding to the secondterminal.

S418. The second UPF entity sends the data packet 1 to the secondterminal through the downlink path corresponding to the second terminal.

Optionally, in this embodiment of this application, the destinationaddressing information carried in the data packet 1 may be broadcastaddress information. After detecting that the destination addressinginformation is the broadcast address information, the first UPF entityor the SMF entity may replace the broadcast address with addressinginformation corresponding to all other terminals different from thefirst terminal in the MLAN to which the first terminal subscribes,further determine, based on the identity of the MLAN and addressinginformation corresponding to a corresponding terminal, a downlink pathcorresponding to the corresponding terminal in the foregoing manner, andsend the data packet 1 to the corresponding terminal through thedownlink path corresponding to the corresponding terminal. This is notspecifically limited in this embodiment of this application.

Optionally, for example, the identity of the MLAN to which the firstterminal subscribes is the same as the identity of the MLAN to which thesecond terminal subscribes, and the second terminal sends a data packet2 to the first terminal. In this case, the data transmission methodprovided in this embodiment of this application further includes thefollowing steps S419 to S425.

S419. The second terminal sends the data packet 2 to the second UPFentity through the uplink path corresponding to the second terminal, sothat the second UPF entity receives the data packet 2 from the firstterminal through the uplink path corresponding to the second terminal,where the data packet 2 carries the addressing information of the secondterminal, and the addressing information of the second terminal is usedas destination addressing information.

Optionally, the data packet 2 may further carry the addressinginformation of the second terminal that is used as source addressinginformation. This is not specifically limited in this embodiment of thisapplication.

S420. The second UPF entity determines, based on the information aboutthe uplink path corresponding to the second terminal, the identity ofthe MLAN to which the second terminal subscribes.

The second UPF entity may determine, based on the information about theuplink path corresponding to the second terminal and the correspondence5, the identity of the MLAN to which the second terminal subscribes.

For example, the second UPF entity may search Table 5, Table 10, Table11, or Table 12 based on the information about the uplink pathcorresponding to the second terminal to obtain the identity of the MLANto which the first terminal subscribes.

S421. The second UPF entity determines the path information of the firstUPF entity based on the identity of the MLAN to which the secondterminal subscribes and the first-terminal addressing information andwith reference to the correspondence 4.

The second UPF entity may determine the path information of the firstUPF entity based on the identity of the MLAN to which the secondterminal subscribes, the first-terminal addressing information, and thecorrespondence 4.

For example, the second UPF entity may search Table 4, Table 10, Table11, or Table 12 based on the identity of the MLAN to which the secondterminal subscribes and the first-terminal addressing information toobtain the path information of the first UPF entity.

Optionally, if the second UPF entity may determine, based on theidentity of the MLAN to which the second terminal subscribes and thefirst-terminal addressing information and with reference to thecorrespondence 7, the downlink path corresponding to the first terminal,it indicates that the first terminal and the second terminal are servedby the same UPF entity. In this case, the second UPF entity may send thedata packet 2 to the first terminal through the downlink pathcorresponding to the first terminal. This is not specifically limited inthis embodiment of this application.

S422. The second UPF entity sends the data packet 2 to the first UPFentity based on the path information of the first UPF entity, so thatthe first UPF entity receives the data packet 2 from the second UPFentity.

S423. The first UPF entity determines, based on the path information ofthe first UPF entity, the identity of the MLAN to which the firstterminal subscribes.

The first UPF entity may determine, based on the path information of thefirst UPF entity and the correspondence 2, the identity of the MLAN towhich the first terminal subscribes.

For example, the first UPF entity may search Table 2, Table 9, or Table11 based on the path information of the first UPF entity to obtain theidentity of the MLAN to which the first terminal subscribes.

S424. The first UPF entity determines, based on the identity of the MLANto which the first terminal subscribes and the first-terminal addressinginformation, the downlink path corresponding to the first terminal.

The first UPF entity may determine, based on the identity of the MLAN towhich the first terminal subscribes, the first-terminal addressinginformation, and the correspondence 3, the downlink path correspondingto the first terminal.

For example, the first UPF entity may search Table 3, Table 9, Table 11,or Table 12 based on the identity of the MLAN to which the firstterminal subscribes and the first-terminal addressing information todetermine the downlink path corresponding to the first terminal.

S425. The first UPF entity sends the data packet 2 to the first terminalthrough the downlink path corresponding to the first terminal.

Optionally, in this embodiment of this application, the destinationaddressing information carried in the data packet 2 may be broadcastaddress information. After detecting that the destination addressinginformation is the broadcast address information, the second UPF entityor the SMF entity may replace the broadcast address with addressinginformation corresponding to all other terminals different from thesecond terminal in the MLAN to which the second terminal subscribes,further determine, based on the identity of the MLAN and addressinginformation corresponding to a corresponding terminal, a downlink pathcorresponding to the corresponding terminal in the foregoing manner, andsend the data packet 2 to the corresponding terminal through thedownlink path corresponding to the corresponding terminal. This is notspecifically limited in this embodiment of this application.

Based on the data transmission method provided in this embodiment ofthis application, after receiving the data packet from the firstterminal through the uplink path corresponding to the first terminal,the first UPF entity may determine the path information of the secondUPF entity based on the information about the uplink path correspondingto the first terminal and the addressing information of the secondterminal, and may further send the data packet to the second UPF entitybased on the path information of the second UPF entity; and the secondUPF entity sends the data packet to the second terminal through thedownlink path corresponding to the second terminal. Alternatively, afterreceiving the data packet from the second terminal through the uplinkpath corresponding to the second terminal, the second UPF entity maydetermine the path information of the first UPF entity based on theinformation about the uplink path corresponding to the second terminaland the first-terminal addressing information, and may further send thedata packet to the first UPF entity based on the path information of thefirst UPF entity; and the first UPF entity sends the data packet to thefirst terminal through the downlink path corresponding to the firstterminal. In this way, local interaction can be implemented between thetwo terminals when the two terminals are served by different UPFentities. For example, local interaction between the two terminals thataccess the same MLAN can be implemented in the MLAN when the twoterminals are served by different UPF entities.

The actions of the first UPF entity and the second UPF entity in stepsS401 a to S425 may be performed by the processor 301 in thecommunications device 300 shown in FIG. 3 by invoking the applicationprogram code stored in the memory 303. This is not limited in thisembodiment of this application.

Optionally, for example, the data transmission system shown in FIG. 1 isapplied to the 5G network shown in FIG. 2. For the scenario 1, anotherdata transmission method provided in an embodiment of this applicationmay be shown in FIG. 5A to FIG. 5C, and includes the following steps.

Steps S501 a to S509 a are the same as steps S401 a to S409 a. Fordetails, refer to the embodiment shown in FIG. 4A. Details are notdescribed herein again.

Steps S501 b to S509 b are the same as steps S401 b to S409 b. Fordetails, refer to the embodiment shown in FIG. 4B. Details are notdescribed herein again.

Steps S510 and S511 are the same as steps S412 and S413. For details,refer to the embodiment shown in FIG. 4C. Details are not describedherein again.

S512. The first UPF entity sends an N4 session message 2 to the SMFentity, so that the SMF entity receives the N4 session message 2 fromthe first UPF entity, where the N4 session message 2 carries theidentity of the MLAN to which the first terminal subscribes and theaddressing information of the second terminal, and the N4 sessionmessage 2 is used to request path information of the UPF entity thatserves the second terminal.

Optionally, if the first UPF entity may determine, based on the identityof the MLAN to which the first terminal subscribes and the addressinginformation of the second terminal and with reference to thecorrespondence 3, the downlink path corresponding to the secondterminal, it indicates that the first terminal and the second terminalare served by the same UPF entity. In this case, the first UPF entitymay send the data packet 1 to the second terminal through the downlinkpath corresponding to the second terminal. This is not specificallylimited in this embodiment of this application.

S513. The SMF entity sends an N4 session message 3 to the first UPFentity, so that the first UPF entity receives the N4 session message 2from the SMF entity, where the N4 session message 2 carries the pathinformation of the second UPF entity that serves the second terminal.

S514. The first UPF entity establishes the correspondence 8.

For related descriptions of the correspondence 8, refer to theembodiment shown in FIG. 4B. Details are not described herein again.

Steps S515 to S518 are the same as steps S415 to S418. For details,refer to the embodiment shown in FIG. 4C. Details are not describedherein again.

Steps S519 and S520 are the same as steps S419 and S420. For details,refer to the embodiment shown in FIG. 4C. Details are not describedherein again.

S521. The second UPF entity sends an N4 session message 4 to the SMFentity, so that the SMF entity receives the N4 session message 4 fromthe second UPF entity, where the N4 session message 4 carries theidentity of the MLAN to which the second terminal subscribes, and thefirst-terminal addressing information, and the N4 session message 4 isused to request path information of the UPF entity that serves the firstterminal.

Optionally, if the second UPF entity may determine, based on theidentity of the MLAN to which the second terminal subscribes and thefirst-terminal addressing information, and with reference to thecorrespondence 7, the downlink path corresponding to the first terminal,it indicates that the first terminal and the second terminal are servedby the same UPF entity. In this case, the second UPF entity may send thedata packet 2 to the first terminal through the downlink pathcorresponding to the first terminal. This is not specifically limited inthis embodiment of this application.

S522. The SMF entity sends an N4 session message 5 to the second UPFentity, so that the second UPF entity receives the N4 session message 5from the SMF entity, where the N4 session message 5 carries the pathinformation of the first UPF entity.

S523. The second UPF entity establishes the correspondence 4.

For related descriptions of the correspondence 4, refer to theembodiment shown in FIG. 4A. Details are not described herein again.

Steps S524 to S527 are the same as steps S422 to S425. For details,refer to the embodiment shown in FIG. 4C. Details are not describedherein again.

A difference between this embodiment shown in FIG. 5A to FIG. 5C and theembodiment shown in FIG. 4A to FIG.4C lies in the embodiment shown inFIG. 4A to FIG. 4C, in the process of establishing an MLAN session, theSMF entity pre-synchronizes path information of a UPF entity to anotherUPF entity in the same MLAN; however, in this embodiment shown in FIG.5A to FIG. 5C, during communication between the terminals, afterreceiving a request that is sent by the first UPF entity and that isused for requesting the path information of the second UPF entity, theSMF entity synchronizes the path information of the second UPF entity tothe first UPF entity.

Optionally, in the embodiment shown in FIG. 5A to FIG. 5C, an N9 tunnelbetween the first UPF entity and the second UPF entity may bepre-established before data transmission, or may be dynamicallyestablished during the data transmission. This is not specificallylimited in this embodiment of this application.

Based on the data transmission method provided in this embodiment ofthis application, local interaction between the two terminals can beimplemented when the two terminals are served by different UPF entities.For example, local interaction between the two terminals that access thesame MLAN can be implemented in the MLAN when the two terminals areserved by different UPF entities.

The actions of the first UPF entity and the second UPF entity in stepsS501 a to S527 may be performed by the processor 301 in thecommunications device 300 shown in FIG. 3 by invoking the applicationprogram code stored in the memory 303. This is not limited in thisembodiment of this application.

Optionally, for example, the data transmission system shown in FIG. 1 isapplied to the 5G network shown in FIG. 2. For the scenario 2, a datatransmission method provided in an embodiment of this application may beshown in FIG. 6A to FIG. 6C, and includes the following steps.

S601. A second terminal moves, and is handed over from a first AN deviceto a second AN device.

For a specific AN device handover manner, refer to an existingimplementation. Details are not described herein.

Before the second terminal moves, both a first terminal and the secondterminal are served by a first UPF entity. In this embodiment of thisapplication, when the two terminals that access the same MLAN are servedby a same UPF entity, a manner of implementing local interaction betweenthe two terminals in the MLAN is not specifically limited. For example,after receiving a data packet from the first terminal through an uplinkpath corresponding to the first terminal, the first UPF entity maydetermine, based on addressing information of a second terminal carriedin the data packet and information about the uplink path correspondingto the first terminal, information about a downlink path correspondingto the second terminal, and further send the data packet to the secondterminal through the downlink path corresponding to the second terminal.This can implement local interaction between the first terminal and thesecond terminal in the MLAN.

S602. The second AN device sends the information about the downlink pathcorresponding to the second terminal to the first UPF entity, so thatthe first UPF entity receives the information about the downlink pathcorresponding to the second terminal from the second AN device.

Optionally, the information about the downlink path corresponding to thesecond terminal may be allocated by an SMF entity and then sent to thefirst UPF entity. This is not specifically limited in this embodiment ofthis application.

S603. The first UPF entity establishes a correspondence 7.

For related descriptions of the correspondence 7, refer to theembodiment shown in FIG. 4B. Details are not described herein again.

Optionally, the correspondence 7 established in this embodiment of thisapplication may be an updated correspondence 7 established before an ANdevice handover occurs, or may be a newly established correspondence 7.This is not specifically limited in this embodiment of this application.

If the correspondence 7 is the updated correspondence 7 establishedbefore the AN device handover occurs, then before the AN device handoveroccurs, the information about the downlink path corresponding to thesecond terminal in the correspondence 7 includes a tunnel identifier ofthe first AN device allocated for the second terminal. After the ANdevice handover occurs, the information about the downlink pathcorresponding to the second terminal in the correspondence 7 includes atunnel identifier of the second AN device allocated for the secondterminal.

S604. The SMF entity selects a second UPF entity.

To be specific, after the second terminal moves, the SMF entity mayreselect a UPF entity after determining that the first UPF entity thatcurrently provides a service is not optimal. Certainly, the SMF entitymay reselect a UPF entity for another reason. This is not specificallylimited in this embodiment of this application.

For a specific manner in which the SMF entity selects the second UPFentity, refer to an existing solution. Details are not described herein.

S605. The SMF entity sends an N4 session message 1 to the second UPFentity, so that the second UPF entity receives the N4 session message 1from the SMF entity, where the N4 session message 1 carries an identityof an MLAN to which the second terminal subscribes, the addressinginformation of the second terminal, and the information about thedownlink path corresponding to the second terminal.

For related descriptions of the addressing information of the secondterminal, refer to step S405 a. Details are not described herein again.

S606. The second UPF entity establishes a correspondence 5, acorrespondence 6, and the correspondence 7.

For related descriptions of the correspondence 5, the correspondence 6,and the correspondence 7, refer to the embodiment shown in FIG. 4B.Details are not described herein again.

The information about the uplink path corresponding to the secondterminal in the correspondence 5 may be allocated by the SMF entity, ormay be allocated by the second UPF entity. This is not specificallylimited in this embodiment of this application. If the information aboutthe uplink path corresponding to the second terminal is allocated by theSMF entity, the N4 session message 1 in step S605 may further carry theinformation about the uplink path corresponding to the second terminal.A general description is provided herein, and details are not describedbelow again.

Path information of the second UPF entity in the correspondence 6 may beallocated by the SMF entity, or may be allocated by the second UPFentity. This is not specifically limited in this embodiment of thisapplication. If the path information of the second UPF entity isallocated by the SMF entity, the N4 session message 1 in step S605 mayfurther carry the path information of the second UPF entity. A generaldescription is provided herein, and details are not described belowagain.

S607. The second UPF entity sends the information about the uplink pathcorresponding to the second terminal to the second AN device, so thatthe second AN device receives the information about the uplink pathcorresponding to the second terminal from the second UPF entity.

S608. The SMF entity sends an N4 session message 2 to the first UPFentity, so that the first UPF entity receives the N4 session message 2from the SMF entity, where the N4 session message 2 carries the identityof the MLAN to which the second terminal subscribes, the addressinginformation of the second terminal, and the path information of thesecond UPF entity.

S609. The first UPF entity deletes the correspondence 7, and establishesa correspondence 8.

For related descriptions of the correspondence 7 and the correspondence8, refer to the embodiment shown in FIG. 4B. Details are not describedherein again.

S610. The SMF entity sends an N4 session message 3 to the second UPFentity, so that the second UPF entity receives the N4 session message 3from the SMF entity, where the N4 session message 3 carries the identityof the MLAN to which the first terminal subscribes, first-terminaladdressing information, and path information of the first UPF entity.

Optionally, in this embodiment of this application, the N4 sessionmessage 1 and the N4 session message 3 may be sent to the second UPFentity by using one message, or may be separately sent to the second UPFentity. This is not specifically limited in this embodiment of thisapplication.

S611. The second UPF entity establishes a correspondence 4.

For related descriptions of the correspondence 4, refer to theembodiment shown in FIG. 4A. Details are not described herein again.

S612. The SMF entity sends an N4 session message 6 to the first UPFentity, so that the first UPF entity receives the N4 session message 6from the SMF entity, where the N4 session message 6 carries the identityof the MLAN to which the first terminal subscribes.

S613. The first UPF entity establishes a correspondence 2.

For related descriptions of the correspondence 2, refer to theembodiment shown in FIG. 4A. Details are not described herein again.

Optionally, in this embodiment of this application, the N4 sessionmessage 2 and the N4 session message 6 may be sent to the first UPFentity by using one message, or may be separately sent to the first UPFentity. This is not specifically limited in this embodiment of thisapplication.

Steps S614 to S627 are the same as steps S412 to S425. For details,refer to the embodiment shown in FIG. 4C. Details are not describedherein again.

Optionally, in this embodiment shown in FIG. 6A to FIG. 6C, an N9 tunnelbetween the first UPF entity and the second UPF entity may bepre-established before a UPF handover occurs, or may be dynamicallyestablished during the UPF handover. This is not specifically limited inthis embodiment of this application.

Based on the data transmission method provided in this embodiment ofthis application, local interaction between the two terminals thataccess the same MLAN can be implemented in the MLAN when the twoterminals are served by different UPF entities.

The actions of the first UPF entity and the second UPF entity in stepsS601 to S627 may be performed by the processor 301 in the communicationsdevice 300 shown in FIG. 3 by invoking the application program codestored in the memory 303. This is not limited in this embodiment of thisapplication.

Optionally, for example, the data transmission system shown in FIG. 1 isapplied to the 5G network shown in FIG. 2. For the scenario 2, anotherdata transmission method provided in an embodiment of this applicationmay be shown in FIG. 7A to FIG. 7C, and includes the following steps.

Steps S701 to S707 are the same as steps S601 to S607. For details,refer to the embodiment shown in FIG. 6A. Details are not describedherein again.

Steps S708 and S709 are the same as steps S612 and S613. For details,refer to the embodiment shown in FIG. 6A. Details are not describedherein again.

S710. The first UPF entity deletes the correspondence 7.

For related descriptions of the correspondence 7, refer to theembodiment shown in FIG. 4B. Details are not described herein again.

Steps S711 to S728 are the same as steps S510 to S527. For details,refer to the embodiment shown in FIG. 5B and FIG. 5C. Details are notdescribed herein again.

A difference between this embodiment shown in FIG. 7A to FIG. 7C and theembodiment shown in FIG. 6A to FIG. 6C lies in the embodiment shown inFIG. 6A to FIG. 6C, during a UPF entity handover, the SMF entitypre-synchronizes path information of a UPF entity to another UPF entityin the same MLAN; however, in this embodiment shown in FIG. 7A to FIG.7C, during communication between the terminals, after receiving arequest that is sent by the first UPF entity and that is used forrequesting the path information of the second UPF entity, the SMF entitysynchronizes the path information of the second UPF entity to the firstUPF entity.

Based on the data transmission method provided in this embodiment ofthis application, local interaction between the two terminals can beimplemented when the two terminals are served by different UPF entities.For example, local interaction between the two terminals that access thesame MLAN can be implemented in the MLAN when the two terminals areserved by different UPF entities.

The actions of the first UPF entity and the second UPF entity in stepsS501 a to S527 may be performed by the processor 301 in thecommunications device 300 shown in FIG. 3 by invoking the applicationprogram code stored in the memory 303. This is not limited in thisembodiment of this application.

Optionally, the embodiments shown in FIG. 6A to FIG. 7C are described byusing an example in which both an AN device handover and the UPF entityhandover occur. Certainly, alternatively, only the AN device handover orthe UPF entity handover may occur. This is not specifically limited inthe embodiments of this application. If only the AN device handoveroccurs, but the UPF entity handover does not occur, only informationabout a downlink path corresponding to a corresponding terminal needs tobe updated. If only the UPF entity handover occurs, but the AN devicehandover does not occur, only a related step after the UPF entityhandover in FIG. 6A to FIG. 6C or FIG. 7A to FIG. 7C needs to beperformed. For details, refer to the embodiments shown in FIG. 6A toFIG. 7C. Details are not described in this embodiment of thisapplication again.

Optionally, in the embodiment shown in FIG. 7A to FIG. 7C, an N9 tunnelbetween the first UPF entity and the second UPF entity may bepre-established before the UPF handover occurs, may be dynamicallyestablished during the UPF handover, or may be dynamically establishedduring data transmission. This is not specifically limited in thisembodiment of this application.

The following provides an MLAN identity configuration procedure by usingan example in which the identity of the MLAN to which a first terminalsubscribes is configured on the first terminal. A schematic flowchart ofthe MLAN identity configuration procedure is shown in FIG. 8, and theprocedure includes the following steps.

S801. When the first terminal subscribes to an MLAN service, a UDMentity stores MLAN subscription information corresponding to the firstterminal, where the MLAN subscription information corresponding to thefirst terminal includes the identity of the MLAN to which the firstterminal subscribes.

Optionally, if the identity of the MLAN to which the first terminalsubscribes corresponds to a specific service area, the MLAN subscriptioninformation corresponding to the first terminal may further includeinformation about the specific service area corresponding to theidentity of the MLAN to which the first terminal subscribes.

Certainly, the information about the specific service area correspondingto the identity of the MLAN to which the first terminal subscribes maybe further configured on another network device. For example, theinformation about the specific service area corresponding to theidentity of the MLAN to which the first terminal subscribes isconfigured on one or more devices of a PCF entity, an AMF entity, and anSMF entity. In this case, when the first terminal initiates an MLANsession establishment procedure, these network devices may determine,based on a current location of the first terminal and the informationabout the specific service area corresponding to the identity of theMLAN to which the first terminal subscribes, whether the first terminalfalls within the specific service area corresponding to the identity ofthe MLAN to which the first terminal subscribes. This is notspecifically limited in this embodiment of this application.

S802. The first terminal sends a registration or re-registration requestto the AMF entity, so that the AMF entity receives the registration orre-registration request from the first terminal.

S803. The AMF entity obtains, from the UDM entity, the identity of theMLAN to which the first terminal subscribes.

Optionally, if the identity of the MLAN to which the first terminalsubscribes corresponds to the specific service area, and the informationabout the specific service area corresponding to the identity of theMLAN to which the first terminal subscribes is not configured on the AMFentity, the AMF entity further obtains, from a device such as the UDMentity, the PCF entity, or the SMF entity configured with theinformation about the specific service area corresponding to theidentity of the MLAN to which the first terminal subscribes, theinformation about the specific service area corresponding to theidentity of the MLAN to which the first terminal subscribes. This is notspecifically limited in this embodiment of this application.

S804. The AMF entity sends a registration response to the firstterminal, so that the first terminal receives the registration responsefrom the AMF entity, where the registration response carries theidentity of the MLAN to which the first terminal subscribes.

Optionally, in this embodiment of this application, after the AMF entityobtains, from the UDM entity, the identity of the MLAN to which thefirst terminal subscribes, if the identity of the MLAN to which thefirst terminal subscribes corresponds to the specific service area, theAMF entity needs to determine, based on information about a currentregistration area of the first terminal and the information about thespecific service area corresponding to the identity of the MLAN to whichthe first terminal subscribes, whether the current registration area ofthe first terminal overlaps the specific service area corresponding tothe identity of the MLAN to which the first terminal subscribes. If thecurrent registration area of the first terminal overlaps the specificservice area corresponding to the identity of the MLAN to which thefirst terminal subscribes, the AMF entity sends the registrationresponse to the first terminal. The registration response carries theidentity of the MLAN to which the first terminal subscribes. Optionally,in this case, the registration response may further include theinformation about the specific service area corresponding to theidentity of the MLAN to which the first terminal subscribes, so that thefirst terminal may initiate, based on the information about the specificservice area corresponding to the identity of the MLAN to which thefirst terminal subscribes, the MLAN session establishment procedure inthe specific service area corresponding to the identity of the MLAN towhich the first terminal subscribes. This is not specifically limited inthis embodiment of this application.

In this way, the first terminal can obtain the identity of the MLAN towhich the first terminal subscribes, and can initiate the MLAN sessionestablishment procedure subsequently based on the identity of the MLANto which the first terminal subscribes. For details, refer to theembodiments shown in FIG. 4A to FIG. 7C. Details are not describedherein again.

In addition, for a procedure in which the identity of the MLAN to whichthe second terminal subscribes is configured on a second terminal, referto the foregoing procedure in which the identity of the MLAN to whichthe first terminal subscribes is configured on the first terminal.Details are not described herein again.

The solutions provided in this application are described above mainlyfrom a perspective of interaction between the network elements. It maybe understood that, to implement the foregoing functions, the first userplane function entity and the second user plane function entity includecorresponding hardware structures and/or software modules for performingthe functions. A person skilled in the art should be easily aware thatunits and algorithm steps in the examples described with reference tothe embodiments disclosed in this specification, may be implemented in aform of hardware or in a form of a combination of hardware and computersoftware in this application. Whether a function is performed byhardware or hardware driven by computer software depends on particularapplications and design constraints of the technical solutions. A personskilled in the art may use different methods to implement the describedfunctions for each particular application, but it should not beconsidered that the implementation goes beyond the scope of thisapplication.

In the embodiments of this application, the first user plane functionentity and the second user plane function entity may be divided intofunction modules based on the foregoing method examples. For example,each function module may be obtained through division based on eachcorresponding function, or two or more functions may be integrated intoone processing module. The integrated module may be implemented in aform of hardware, or may be implemented in a form of a software functionmodule. It should be noted that, in the embodiments of this application,module division is an example, and is merely a logical functiondivision. In actual implementation, another division manner may be used.

For example, if the function modules are divided through integration,FIG. 9 is a schematic structural diagram of the first user planefunction entity in the foregoing embodiments. The first user planefunction entity 90 includes a transceiver module 901 and a processingmodule 902. The transceiver module 901 is configured to receive a datapacket from a first terminal through an uplink path corresponding to thefirst terminal, where the data packet carries addressing information ofa second terminal, and the first user plane function entity is a userplane function entity currently accessed by the first terminal. Theprocessing module 902 is configured to determine path information of asecond user plane function entity based on information about the uplinkpath corresponding to the first terminal and the addressing informationof the second terminal, where the second user plane function entity is auser plane function entity currently accessed by the second terminal.The transceiver module 901 is further configured to send the data packetto the second user plane function entity based on the path informationof the second user plane function entity, so that the second user planefunction entity sends the data packet to the second terminal through adownlink path corresponding to the second terminal.

Optionally, the processing module 902 is configured to determine, basedon the information about the uplink path corresponding to the firstterminal, an identity of an MLAN to which the first terminal subscribes;and determine the path information of the second user plane functionentity based on the identity of the MLAN and the addressing informationof the second terminal.

Optionally, the processing module 902 is further configured to afterdetermining, based on the information about the uplink pathcorresponding to the first terminal, the identity of the MLAN to whichthe first terminal subscribes, determine, based on the identity of theMLAN and the addressing information of the second terminal, thatinformation about the downlink path corresponding to the second terminalis not stored.

Optionally, that the processing module 902 determines, based on theinformation about the uplink path corresponding to the first terminal,the identity of the MLAN to which the first terminal subscribes includesdetermining, based on the information about the uplink pathcorresponding to the first terminal and a first correspondence, theidentity of the MLAN to which the first terminal subscribes, where thefirst correspondence includes a correspondence between the informationabout the uplink path corresponding to the first terminal and theidentity of the MLAN.

Optionally, that the processing module 902 determines the pathinformation of the second user plane function entity based on theidentity of the MLAN and the addressing information of the secondterminal includes determining, the path information of the second userplane function entity based on the identity of the MLAN, the addressinginformation of the second terminal, and a second correspondence, wherethe second correspondence includes a correspondence between theaddressing information of the second terminal, the path information ofthe second user plane function entity, and the identity of the MLAN.

Optionally, that the processing module 902 determines the pathinformation of the second user plane function entity based on theidentity of the MLAN and the addressing information of the secondterminal includes sending the identity of the MLAN and the addressinginformation of the second terminal to a session management functionentity, where the identity of the MLAN and the addressing information ofthe second terminal are used to determine the path information of thesecond user plane function entity; and receiving from the sessionmanagement function entity, the path information of the second userplane function entity.

Optionally, the information about the uplink path corresponding to thefirst terminal includes a tunnel identifier of the first user planefunction entity allocated for the first terminal, the information aboutthe downlink path corresponding to the second terminal includes a tunnelidentifier of an access device allocated for the second terminal, andthe path information of the second user plane function entity includes atunnel identifier of the second user plane function entity.

All related content of the steps in the foregoing method embodiment maybe cited in function descriptions of corresponding function modules, anddetails are not described herein again.

In this embodiment, the first user plane function entity 90 is presentedin a form in which each function module is obtained through integration.The “module” herein may be an application-specific integrated circuit(ASIC), a circuit, a processor and a memory that execute one or moresoftware programs or firmware programs, an integrated logic circuit,and/or another component that can provide the foregoing function. In asimple embodiment, a person skilled in the art may figure out that thefirst user plane function entity 90 may be in a form shown in FIG. 3.

For example, the processor 301 in FIG. 3 may invoke the computerexecutable instruction stored in the memory 303, and the first userplane function entity 90 is enabled to perform the data transmissionmethod in the foregoing method embodiment.

The functions/implementation processes of the transceiver module 901 andthe processing module 902 in FIG. 9 may be implemented by the processor301 in FIG. 3 by invoking the computer executable instruction stored inthe memory 303. Alternatively, the function/implementation process ofthe processing module 902 in FIG. 9 may be implemented by the processor301 in FIG. 3 by invoking the computer executable instruction stored inthe memory 303, and the function/implementation process of thetransceiver module 901 in FIG. 9 may be implemented by thecommunications interface 304 in FIG. 3.

The first user plane function entity provided in this embodiment of thisapplication may be configured to perform the foregoing data transmissionmethod. Therefore, for technical effects that can be obtained by thefirst user plane function entity, refer to the foregoing methodembodiment. Details are not described herein again.

In this embodiment, the first user plane function entity 90 is presentedin a form in which each function module is obtained through integration.Certainly, the function modules of the first user plane function entitymay be obtained through division based on corresponding functions in theembodiments of this application. This is not specifically limited inthis embodiment of this application.

Optionally, an embodiment of this application provides a chip system.The chip system includes a processor configured to support a first userplane function entity in implementing the foregoing data transmissionmethod, for example, determining the path information of the second userplane function entity based on the information about the uplink pathcorresponding to the first terminal and the addressing information ofthe second terminal. In a possible design, the chip system furtherincludes a memory. The memory is configured to store a programinstruction and data that are required by the first user plane functionentity. The chip system may include a chip, or may include a chip andanother discrete component. This is not specifically limited in thisembodiment of this application.

All or some of the foregoing embodiments may be implemented by usingsoftware, hardware, firmware, or any combination thereof. When asoftware program is used to implement the embodiments, the embodimentsmay be implemented or partially in a form of a computer program product.The computer program product includes one or more computer instructions.When the computer program instructions are loaded and executed on acomputer, the procedures or functions according to the embodiments ofthis application are all or partially generated. The computer may be ageneral-purpose computer, a dedicated computer, a computer network, orother programmable apparatuses. The computer instructions may be storedin a computer-readable storage medium or may be transmitted from acomputer-readable storage medium to another computer-readable storagemedium. For example, the computer instructions may be transmitted from awebsite, computer, server, or data center to another website, computer,server, or data center in a wired (for example, a coaxial cable, anoptical fiber, or a digital subscriber line (DSL)) or wireless (forexample, infrared, radio, and microwave, or the like) manner. Thecomputer-readable storage medium may be any usable medium accessible bya computer, or a data storage device, such as a server or a data center,integrating one or more usable media. The usable medium may be amagnetic medium (for example, a floppy disk, a hard disk, or a magnetictape), an optical medium (for example, a DVD), a semiconductor medium(for example, a solid-state drive (SSD)), or the like.

Although this application is described with reference to theembodiments, in a process of implementing this application that claimsprotection, a person skilled in the art may understand and implementanother variation of the disclosed embodiments by viewing theaccompanying drawings, disclosed content, and the appended claims. Inthe claims, “comprising” does not exclude another component or anotherstep, and “a” or “one” does not exclude a case of “a plurality of”. Asingle processor or another unit may implement several functionsenumerated in the claims. Some measures are described in dependentclaims that are different from each other, but this does not mean thatthese measures cannot be combined to produce a better effect.

Although this application is described with reference to specificfeatures and the embodiments thereof, it is clearly that variousmodifications and combinations may be made to this application withoutdeparting from the spirit and scope of this application.Correspondingly, the specification and accompanying drawings are merelyexample descriptions of this application defined by the accompanyingclaims, and are considered as any or all of modifications, variations,combinations, or equivalents that cover the scope of this application. Aperson skilled in the art can make various modifications and variationsto this application without departing from the spirit and scope of thisapplication. This application is intended to cover these modificationsand variations of this application provided that the modifications andvariations fall within the scope of protection defined by the followingclaims and their equivalent technologies.

1. A data transmission method comprising: receiving, by a first userplane function entity, a data packet from a first terminal through anuplink path corresponding to the first terminal, wherein the data packetcarries first addressing information of a second terminal, and whereinthe first user plane function entity currently serves the firstterminal; determining, by the first user plane function entity, firstpath information of a second user plane function entity based oninformation about the uplink path corresponding to the first terminaland the first addressing information, wherein the second user planefunction entity currently serves the second terminal; sending, by thefirst user plane function entity, the data packet to the second userplane function entity based on the first path information; receiving, bythe second user plane function entity, the data packet from the firstuser plane function entity; and sending, by the second user planefunction entity, the data packet to the second terminal through adownlink path corresponding to the second terminal.
 2. The method ofclaim 1, wherein determining the first path information comprises:determining, by the first user plane function entity based on theinformation about the uplink path corresponding to the first terminal,an identity of a mobile local area network (MLAN) of the first terminal;and determining, by the first user plane function entity, the first pathinformation based on the identity of the MLAN and the first addressinginformation.
 3. The method of claim 2, wherein determining the identityof the MLAN comprises determining, by the first user plane functionentity based on the information about the uplink path corresponding tothe first terminal and a first correspondence, the identity of the MLAN,wherein the first correspondence is between the information about theuplink path corresponding to the first terminal and the identity of theMLAN.
 4. The method of claim 2, wherein determining the first pathinformation comprises determining, by the first user plane functionentity, the first path information based on the identity of the MLAN,the first addressing information, and a second correspondence, whereinthe second correspondence is between the first addressing information,the first path information, and the identity of the MLAN.
 5. The methodof claim 1, further comprising determining, by the second user planefunction entity based on the first path information and the firstaddressing information, the downlink path.
 6. The method of claim 5,wherein determining the downlink path comprises: determining, by thesecond user plane function entity based on the first path information,an identity of a mobile local area network (MLAN) of the secondterminal; and determining, by the second user plane function entitybased on the identity of the MLAN and the first addressing information,the downlink path.
 7. The method of claim 1, wherein the informationabout the uplink path corresponding to the first terminal comprises afirst tunnel identifier of the first user plane function entityallocated for the first terminal, and wherein the first path informationcomprises a second tunnel identifier of the second user plane functionentity.
 8. The method of claim 1, further comprising establishing, by asession management function entity, a tunnel between the first userplane function entity and the second user plane function entity, whereinthe tunnel is at an MLAN granularity.
 9. The method of claim 8, whereinestablishing the tunnel comprises establishing, by the sessionmanagement function entity, the tunnel in a process of establishing asession of the first terminal.
 10. The method of claim 8, whereinestablishing the tunnel comprises: sending, by the session managementfunction entity, a first N4 session message to the first user planefunction entity, wherein the first N4 session message comprises anidentity of an MLAN of the second terminal, the first addressinginformation, and the first path information; and saving, by the firstuser plane function entity, a correspondence between the firstaddressing information, the first path information, and the identity ofthe MLAN.
 11. The method of claim 10, wherein establishing the tunnelcomprises: sending, by the session management function entity, a secondN4 session message to the second user plane function entity, wherein thesecond N4 session message comprises an identifier of an MLAN of thefirst terminal, second addressing information of the first terminal, andsecond path information of the first user plane function entity; andsaving, by the first user plane function entity, a correspondencebetween the second addressing information, the second path informationof the first user plane function entity, and the identifier of the MLANof the first terminal.
 12. The method of claim 8, further comprisingdetermining, by the session management function entity, that the MLANcomprises a cross user plane function entity.
 13. A data transmissionsystem comprising: a first user plane function entity configured to:receive a data packet from a first terminal through an uplink pathcorresponding to the first terminal, wherein the data packet carriesaddressing information of a second terminal, and wherein the first userplane function entity currently serves the first terminal; determinepath information of a second user plane function entity based oninformation about the uplink path corresponding to the first terminaland the addressing information, wherein the second user plane functionentity currently serves the second terminal; and send the data packet tothe second user plane function entity based on the path information; andthe second user plane function entity configured to: receive the datapacket from the first user plane function entity; and send the datapacket to the second terminal through a downlink path corresponding tothe second terminal.
 14. The data transmission system of claim 13,wherein the first user plane function entity is further configured to:determine, based on the information about the uplink path correspondingto the first terminal, an identity of a mobile local area network (MLAN)of the first terminal; and determine, the path information based on theidentity of the MLAN and the addressing information.
 15. The datatransmission system of claim 14, wherein the first user plane functionentity is further configured to determine, based on the informationabout the uplink path corresponding to the first terminal and a firstcorrespondence, the identity of the MLAN, and wherein the firstcorrespondence comprises a correspondence between the information aboutthe uplink path corresponding to the first terminal and the identity ofthe MLAN.
 16. The data transmission system of claim 14, wherein thefirst user plane function entity is further configured to determine thepath information based on the identity of the MLAN, the addressinginformation, and a second correspondence, and wherein the secondcorrespondence comprises a correspondence between the addressinginformation, the path information, and the identity of the MLAN.
 17. Thedata transmission system of claim 13, wherein the second user planefunction entity is further configured to determine, based on the pathinformation and the addressing information, the downlink path.
 18. Thedata transmission system of claim 17, wherein the second user planefunction entity is further configured to determine, based on the pathinformation, an identity of a mobile local area network (MLAN) of thesecond terminal; and determine, based on the identity of the MLAN andthe addressing information, the downlink path.
 19. The data transmissionsystem of claim 13, wherein the system further comprises a sessionmanagement function entity configured to establish a tunnel between thefirst user plane function entity and the second user plane functionentity, wherein the tunnel is at an MLAN granularity.
 20. The datatransmission system of claim 19, wherein the session management functionentity is further configured to send an N4 session message to the firstuser plane function entity, wherein the N4 session message comprises anidentity of an MLAN of the second terminal, the addressing information,and the path information, and wherein the first user plane functionentity is further configured to save a correspondence between theaddressing information, the path information, and the identity of theMLAN of the second terminal.
 21. The data transmission system of claim19, wherein the session management function entity is further configuredto determine that the MLAN comprises a cross user plane function entityscenario.